#ifndef _NE_ANIMATION_FILE_FORMAT_H_
#define _NE_ANIMATION_FILE_FORMAT_H_

#include <neinit.h>

namespace ne
{
    const uint32_t ANIMATION_FILE_MAGIC_NUMBER = 0x1222;
    const uint32_t ANIMATION_FILE_VERSION = 1;
    const uint32_t MAX_STRING_LENGTH_IN_ANIMATION_FILE = 0x80;

    struct AnimationGroupHeader
    {
        uint32_t mMagicNum;
        uint32_t mVersion;
        char mName[MAX_STRING_LENGTH_IN_ANIMATION_FILE];
        uint32_t mNumAnimations;
        uint32_t mAnimationFileNameOffset;
    };

    struct AnimationHeader
    {
        uint32_t mMagicNum;
        uint32_t mVersion;
        char mName[MAX_STRING_LENGTH_IN_ANIMATION_FILE];
        real mLength;
        uint32_t mNumNodeTracks;
        uint32_t mNodeTrackOffset;
    };

    struct AnimationTrackHeader
    {
        uint16_t mHandle;
        uint32_t mNumKeyFrames;
        uint32_t mKeyFrameOffset;
    };

    struct TransformKeyFrameHeader
    {
        real mTime;
        real mTrandlate[3];
        real mRotate[4];
        real mScale[3];
    };
}

#endif
